<!--
	作者：王泽欣
	时间：2016-01-13
	描述：已注释
-->
<!DOCTYPE html>
<html>
<head lang="en">
    <meta charset="UTF-8">
    <title>test</title>
</head>
<body>

</body>
<script type="text/javascript">
	doTheThing()
    function doTheThing() {
        console.log(definedLater);//未定义
        var definedLater;//这里才开始定义
        definedLater = 'I am defined!'
        console.log(definedLater)

        console.log(definedSimulateneously);//同上
        var definedSimulateneously = 'I am defined!'//定义的同时赋值

        console.log(definedSimulateneously)

        doSomethingElse();//调用一个函数
        function doSomethingElse(){
            console.log('I did it!');
        }


        functionVar();

        var functionVar = function(){//这不是一个函数而是一个变量
            console.log('I did it!');
        }
    }
</script>
</html>
